package com.kerrykidz.system.dao.mapper;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.kerrykidz.scminvoicing.dao.model.GblScmPrdCateEntity;
import com.kerrykidz.system.dao.model.KdeVerPrdAndPaymentEntity;
import com.kerrykidz.system.dao.model.KdeVoucherEntEntity;
import com.kerrykidz.system.dao.model.KdeVoucherRecEntity;
import com.rdp.framework.exception.RDPException;

@Repository
public interface KdeVoucherRecEntityMapper {
	
	/**凭证内码*/
	public void insertBatchKdeVoucherRecEntity(KdeVoucherRecEntity kdeVoucherRecEntity) throws RDPException;
	public void insertBatchVrePrd(@Param("kdeVerPrdAndPaymentEntity")List<KdeVerPrdAndPaymentEntity> kdeVerPrdAndPaymentEntityList) throws RDPException;
	public void insertBatchVrePayment(@Param("kdeVerPrdAndPaymentEntity")List<KdeVerPrdAndPaymentEntity> kdeVerPrdAndPaymentEntityList) throws RDPException;
	
	public void updateKdeVoucherRecEntity(KdeVoucherRecEntity kdeVoucherRecEntity) throws RDPException;
	
	/**
	 * 获取k3数据  对接到  金蝶数据库中的数据 
	 * @param kdeVoucherRecEntity
	 * @return
	 * @throws RDPException
	 * @date: 2014年11月27日
	 */
	public List<Map<String,Object>> getK3RecSynchronousData(KdeVoucherRecEntity kdeVoucherRecEntity)throws RDPException;
	public List<Map<String,Object>> getK3EntSynchronousData(KdeVoucherEntEntity kdeVoucherEntEntity)throws RDPException;
	
	
	
	/**凭证内码记录*/
	public void  insertBatchKdeVoucherEntEntity(KdeVoucherEntEntity kdeVoucherEntEntity) throws RDPException;
	public void  updateBatchKdeVoucherEntEntity(KdeVoucherEntEntity kdeVoucherEntEntity) throws RDPException;
	/**
	 *  获取凭证内码
	 * @param orderId
	 * @param vocheType
	 * @return
	 * @throws RDPException
	 * @date: 2014年11月3日
	 */
	public KdeVoucherRecEntity getByKdeVocherRecWhereOrderIdAndVocherType(@Param("orderId")String orderId,@Param("vocheType")String vocheType)throws RDPException;
	
	/**
	 * K3查询单次票
	 * @param date
	 * @return
	 * @throws RDPException
	 */
	public List<Map<String, Object>> findSingleTicket(@Param("date") String date)throws RDPException;
	public List<Map<String, Object>> findSingleTicketEnter(@Param("date") String date)throws RDPException;

	/**
	 * 会籍 
	 * @param date
	 * @return
	 * @date: 2014年10月21日
	 */
	//新增的会员
	public List<Map<String, Object>> findAddMember(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findAddMemberEnter(@Param("date")String date) throws RDPException;
	//会员费分摊
	public List<Map<String, Object>> findAvgMember(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findAvgMemberEnter(@Param("date")String date) throws RDPException;
	//会员退会
	public List<Map<String, Object>> findRetreatMember(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findRetreatMemberEnter(@Param("date")String date) throws RDPException;
	
	/**
	 * 储值
	 * @param date
	 * @return
	 * @date: 2014年10月21日
	 */
	//新增储值
	public List<Map<String, Object>> findRecharge(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findRechargeEnter(@Param("date")String date) throws RDPException;
	//储值消费
	public List<Map<String, Object>> findRechargeConsume(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findRechargeConsumeEnter(@Param("date")String date) throws RDPException;
	//储值消费退款
	public List<Map<String, Object>> findRechargeConsumeRefund(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findRechargeConsumeRefundEnter(@Param("date")String date) throws RDPException;
	//余额退款
	public List<Map<String, Object>> findBalanceRefund(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findBalanceRefundEnter(@Param("date")String date) throws RDPException;
	//过期余额
	public List<Map<String, Object>> findExpiredBalance(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findExpiredBalanceEnter(@Param("date")String date) throws RDPException;
	
	/**
	 * 派对团体
	 * findExpiredBalance
	 * @param date
	 * @return
	 * @date: 2014年10月21日
	 */
	//新增预约
	public List<Map<String, Object>> findPartyPrepay(@Param("date")String date) throws RDPException;
	public List<Map<String, Object>> findPartyPrepayEnter(@Param("date")String date) throws RDPException;
	//修改预约
	public List<Map<String, Object>> findPartyUpdate(@Param("date")String date)throws RDPException;
	public List<Map<String, Object>> findPartyUpdateEnter(@Param("date")String date)throws RDPException;
	//取消预约
	public  List<Map<String,Object>> findCancelRes(@Param("date")String date)throws RDPException;
	public  List<Map<String,Object>> findCancelResEnter(@Param("date")String date)throws RDPException;
	//派对团体结算
	public List<Map<String, Object>> findCompletedRes(@Param("date")String date,@Param("idList")List<GblScmPrdCateEntity> idList)throws RDPException;
	public List<Map<String, Object>> findCompletedResEnter(@Param("date")String date,@Param("idList")List<GblScmPrdCateEntity> idList)throws RDPException;
	
}